# -*- coding: utf-8 -*-
# File : server.py
# Author: taoyahui
# Date : 2022/5/25

from flask import Flask, render_template, config
# 相对路径的写法
app = Flask(__name__, template_folder='template_box')
# 绝对路径的写法
# app = Flask(__name__, template_folder='/Users/taoyahui/student_proj/python-profession/python_web/test/template_box')
app.config.from_object(config)

@app.route('/demo/')
def demo():
    return "<h2>手写html</h2>"


@app.route('/demo01/')
def demo01():
    return render_template('login.html')


@app.route('/demo02/')
def demo02():
    return render_template('login02.html')

if __name__ == '__main__':
    app.run()
